import request from '@/utils/request'

// 学生列表
export const getStuList = (params) => request.get('/students', { params })

// 根据Id查询学生
export const getStuById = (id) => request.get(`/students/${id}`)

// 新增学生
export const addStu = (data) => request.post('/students', data)

// 修改学生
export const updateStu = (data) => request.put('/students', data)

// 删除学生
export const delStu = (ids) => request.delete(`/students/${ids}`)

// 违纪处理
export const handleVio = (id, score) => request.put(`/students/violation/${id}/${score}`)